package com.mingqijia.gassafety.webserver.request;

import com.alibaba.fastjson.annotation.JSONField;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.util.Date;

/**
 * @author mby
 * @version 1.0.0
 * @ClassName SaveConsumerServiceInfoRequest.java
 * @Description TODO
 * @createTime 2024-01-12
 */
@Data
@ApiModel("新增客户服务信息")
public class SaveConsumerServiceInfoRequest {

    //主键id
    @ApiModelProperty(value = "客户服务id")
    @NotNull(message = "id不能为空")
    private Integer id;

    @ApiModelProperty("客户 id")
    @NotNull(message = "客户id不能为空")
    private Integer consumerId;

    @ApiModelProperty("imei")
    @NotNull(message = "imei不能为空")
    private String imei;

    //服务信息
    @ApiModelProperty(value = "服务信息")
    @Length(max = 100,message = "服务信息最多输入100个字符")
    private String serviceInfo;

    //服务开始日期
    @ApiModelProperty(value = "服务开始日期")
    @JsonFormat(pattern = "yyyy-MM-dd", timezone="GMT+8")
    @NotNull(message = "服务开始日期不能为空")
    private Date startDate;

    //服务结束日期
    @ApiModelProperty(value = "服务结束日期")
    @JsonFormat(pattern = "yyyy-MM-dd", timezone="GMT+8")
    @NotNull(message = "服务结束日期不能为空")
    private Date endDate;

    //服务信息
    @ApiModelProperty(value = "备注")
    @Length(max = 200,message = "备注最多输入200个字符")
    private String remark;

    @ApiModelProperty("服务套餐id")
    private Integer pkgId;

}